package com.photographysharing.mapper;

import com.photographysharing.dto.CommentDTO;
import com.photographysharing.entity.Comments;
import com.baomidou.mybatisplus.core.mapper.BaseMapper;
import org.apache.ibatis.annotations.Mapper;
import org.apache.ibatis.annotations.Param;

import java.util.List;

/**
* @author Z
* @description 针对表【comments】的数据库操作Mapper
* @createDate 2024-05-14 21:15:11
* @Entity com.photographysharing.entity.Comments
*/
@Mapper
public interface CommentsMapper extends BaseMapper<Comments> {

    List<CommentDTO> getComments(@Param("photoId") String photoId);

    List<CommentDTO> selectByPag(@Param("index") int index,@Param("size") int size,@Param("name") String name,@Param("userName") String userName);

    int selectByPagCount(@Param("name") String name,@Param("userName") String userName);
}




